import http from '../index';

export const getAll = (data) => http({
    url: '/api/commissions?' + data,
    method: 'get',
    data
})

export const addData = (data) => http({
    url: '/api/commissions',
    method: 'post',
    data
})

export const editData = (data) => http({
    url: '/api/commissions',
    method: 'put',
    data
})

export const getBy = (data) => http({
    url: '/api/commissions/selectByCondition?' + data,
    method: 'get',
    data
})

export const createPDF = (data) => http({
    url: '/api/commissions/createPdf?wthtbh=' + data,
    method: 'post',
    data
})

export const delData = (data) => http({
    url: '/api/commissions/' + data,
    method: 'delete',
})

export const addLotData = (data) => http({
    url: '/api/lots',
    method: 'post',
    data
})

export const uploadExcel = (data) => http({
    url: '/api/lots/upload',
    method: 'post',
    data
})

export const submit = (data) => http({
    url: '/api/commissions/Submit?' + data,
    method: 'put',
})

export const shelves = (data) => http({
    url: '/api/commissions/Shelves?' + data,
    method: 'put',
})